﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>
<%@ Import Namespace="ElectronicRecords.Models" %>
<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Справочник процедур
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    
    <h2>
       <center><%=ViewData["Title"] %><br /></center> 
        <%=Html.ActionLink("Создать", "Create", new { }, new { @class = "g-button" })%>
    </h2>

    <table id="maintable" >
        <tr>
            <th style="width:10%">
                Действие
            </th>
            <th style="width:10%">
                ID
            </th>
            <th style="width:40%">
                Наименование процедуры
            </th>
             <th style="width:40%">
                Длительность
            </th>
        </tr>
        <% foreach (Procedurs p in (IEnumerable<Procedurs>)ViewData["Procedurs"])
           {%>
        <tr>
            <td>
                <a href= "Procedure/<%=p.ID_Procedure %>"><img height="24" width="24" src="../../img/sherlock.png" ></a>
                <a href= "Edit/<%=p.ID_Procedure %>"><img height="24" width="24"  src="../../img/textedit.png" ></a>
                
            </td>
            <td>
                <%=p.ID_Procedure %>
            </td>
            <td>
                <%=p.Name %>
            </td>
             <td>
                <%=p.Length %>
            </td>
        </tr>
        <%} %>
    </table>
</asp:Content>
